package com.falcon.core.utils;

import com.falcon.core.domain.LoginUserInfo;

/** 当前用户信息
 * @author zongf
 * @date 2025-02-07
 **/
public class AuthenticationUtil {

    private static ThreadLocal<LoginUserInfo> currentUser = new ThreadLocal<>();

    public static LoginUserInfo getCurrentUser() {
        return currentUser.get();
    }

    public static void setCurrentUser(LoginUserInfo loginUserInfo) {
        AuthenticationUtil.currentUser.set(loginUserInfo);
    }

}
